package lk.mrt.cse.wihidum.storage;

import lk.mrt.cse.wihidum.storage.*;

import java.util.ArrayList;

public class Topology
{

    private String myId;
    private String myAddress = null;
    private String myRole = null;

    private NeighbourBroker primarySuperUnit = new NeighbourBroker();

    private ArrayList<NeighbourBroker> superUnits = new ArrayList<NeighbourBroker>();
    private ArrayList<NeighbourBroker> peerUnits = new ArrayList<NeighbourBroker>();
    private ArrayList<NeighbourBroker> subUnits = new ArrayList<NeighbourBroker>();

    public void setPeerUnits(ArrayList<NeighbourBroker> peerUnits)
    {

        this.peerUnits = peerUnits;
    }

    public ArrayList<NeighbourBroker> getPeerUnits()
    {
        return peerUnits;
    }

    public NeighbourBroker getPrimarySuperUnit()
    {
        return primarySuperUnit;
    }

    public void setPrimarySuperUnit(NeighbourBroker primarySuperUnit)
    {
        this.primarySuperUnit = primarySuperUnit;
    }


    public void setSuperUnits(ArrayList<NeighbourBroker> superUnits)
    {

        this.superUnits = superUnits;
    }

    public ArrayList<NeighbourBroker> getSuperUnits()
    {
      return superUnits;
    }

    public void setSubUnits(ArrayList<NeighbourBroker> subUnits)
    {
        this.subUnits = subUnits;
    }

    public ArrayList<NeighbourBroker> getSubUnits()
    {
        return subUnits;
    }

    public void setMyId(String myId)
    {
        this.myId = myId;
    }

    public String getMyId()
    {
        return myId;
    }

    public void setMyAddress(String myAddress)
    {
        this.myAddress = myAddress;
    }

    public String getMyAddress()
    {
        return myAddress;
    }

    public void setMyRole(String myRole)
    {
        this.myRole = myRole;
    }

    public String getMyRole()
    {
        return myRole;
    }
}
